package com.activiti.z_six.service;

import com.activiti.z_six.entity.taskAssignee.FlowElementAttrs;
import com.activiti.z_six.util.AjaxResponse;

import java.util.HashMap;

public interface ProcessDefinitionService {
    /*
        获取流程的部署列表
     */
    public AjaxResponse getDeployment(Integer page,Integer pagesize,String sortid,String name);
    /*
    发布流程
     */
    public AjaxResponse deployWithBPMNJS(String BPMNXml);
    /*
    更新流程配置
     */
    public AjaxResponse updateDeployment(String process_key,String deploymentId,String flowSort,String name,
                                         String form_type,String formMap,String form_url,String mapJson);
    /*
    获取节点attrs
     */
    public FlowElementAttrs getFlowElementAttrs(String task_def_id);
    public FlowElementAttrs getFlowElementFormAttrs(String process_key);
    /*
    获取流程设置相关的枚举数据
     */
    public HashMap<String,Object> getFlowEnum();
    /*
    获取流程类别
     */
    public AjaxResponse getFlowSort(Integer page,Integer pagesize);
    /*
    获取流程类别
     */
    public AjaxResponse getFlowSortAll();
    public AjaxResponse getFlowSortTree();
    /*
    获取流程发起页面数据
     */
    public AjaxResponse getSatrtPageData();
    /*
    增加流程分类
     */
    public AjaxResponse addFlowSort(String name,Long parentId);
    /*
    保存修改
     */
    public AjaxResponse saveFlowSort(Long id,String name,Long parentId);

    /**
     * 删除流程定义
     * @param deploymentId
     * @return
     */
    public AjaxResponse deleteDefinition(String deploymentId);

    /**
     * 删除流程分类
     * @param id
     * @param name
     * @param parentId
     * @return
     */
    public AjaxResponse deleteFlowSort(Long id,String name,Long parentId);
}
